-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Jenkinsfile: pull latest SDK from downloads server #47
Jenkinsfile: pull latest SDK from downloads server #47
Conversation
5fb60e4
to
7083502
Compare
Jenkinsfile
Outdated
def url = new URL('http://downloads.creatordev.io/openwrt/release.json') | ||
def object = jsonParse(url) | ||
println object.versions.openwrt, object.board, object.versions.toolchain | ||
def sdkUrl = [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using a format string would make this easier to read?
Jenkinsfile
Outdated
def url = new URL('http://downloads.creatordev.io/openwrt/release.json') | ||
def object = jsonParse(url) | ||
println object.versions.openwrt, object.board, object.versions.toolchain | ||
def sdkUrl = [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps add the word latest in the variable name?
Jenkinsfile
Outdated
|
||
@NonCPS | ||
def jsonParse(def json) { | ||
def object = new JsonSlurper().parse(json) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
object is a poor name for OOP
Jenkinsfile
Outdated
object.versions.toolchain, | ||
'.tar.bz2'].join() | ||
println sdkUrl | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Perhaps all of this should go in a function called getLatestSdkUrl?
f6ed8c4
to
1756a94
Compare
Signed-off-by: Nikhil Zinjurde <[email protected]>
1756a94
to
4b41152
Compare
This closes #46
Signed-off-by: Nikhil Zinjurde [email protected]